package cloud.maque.admin.service;

import cloud.maque.admin.domain.entity.MqRole;
import cloud.maque.admin.domain.vo.RoleVo;
import cloud.maque.framework.common.request.PaginateDataResquest;
import com.baomidou.mybatisplus.extension.service.IService;
import com.github.pagehelper.PageInfo;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author 4color
 * @description 角色表服务层
 * @date 2023-03-17
 */
@Service
public interface MqRoleService extends IService<MqRole> {

    /**
     * 插入一条记录
     *
     * @param RoleVo 记录对象
     * @return 是否成功
     */
    RoleVo saveRole(RoleVo RoleVo);

    Boolean delete(String roleId,String tenantId);

    Integer countByGroupId(String groupId);

    RoleVo getDetail(String roleId);

    /**
     * 分页查询
     *
     * @param pageReq
     * @return
     */
    PageInfo<MqRole> page(PaginateDataResquest<MqRole> pageReq);


    List<MqRole> getDetails(List<String> roleIds);
}
